package com.gr.service.impl;

import com.gr.entity.Type;
import com.gr.mapper.TypeMapper;
import com.gr.service.TypeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class TypeServiceImpl implements TypeService {
    @Autowired
    private TypeMapper typeMapper;
    @Override
    public List<Type> selectAllType() {
        return typeMapper.selectAllType();
    }

    @Override
    public List<Type> selectAllTypeAndBooKNum() {
        return typeMapper.selectAllTypeAndBooKNum();
    }

    @Override
    public void insertType(Type type) {
        typeMapper.insertType(type);
    }

    @Override
    public void deleteTypeById(Integer id) {
        typeMapper.deleteTypeById(id);
    }

}
